import request from '@/utils/request'

// 查询task列表
export function listTask(query) {
  return request({
    url: '/task/list',
    method: 'get',
    params: query
  })
}

// 查询表单
export function formDataShow(taskID,businessKey) {
  return request({
    url: '/task/formDataShow/'+taskID,
    method: 'get',
  })
}

// 审核提交
export function formDataSave(taskID,businessKey,processType,data) {
  return request({
    url: '/task/formDataSave/'+taskID+"/"+processType,
    method: 'post',
    data:data
  })
}

export function getDefinitionsByInstanceId(instanceId) {
  return request({
    url: '/processDefinition/getDefinitions/' + instanceId,
    method: 'get'
  })
}


export function getHistoryInfo(query) {
  return request({
    url: '/task/getHistoryInfo',
    method: 'get',
    params: query
  })
}



